import { get, post, put, remove } from "./index.js";

export const list = function (data) {
  return get("permission", data);
};

export const children = function (data) {
  return get("permission/children", data);
};

export const create = function (data) {
  return post("permission", data);
};

export const saveOne = function (data) {
  return put("permission/save", data);
};

export const deleteOne = function (data) {
  return put("permission/delete", data);
};

export const updateOne = function (data) {
  return put("permission/update", data);
};

export default {
  list,
  children,
  create,
  updateOne,
  saveOne,
  deleteOne,
};
